package component
{
	import functional.ADclickAble;
	import functional.ADrollOutAble;
	import functional.ADrollOverAble;
	
	import kit.FilterKit;
	
	public class ADbutton extends ADbaseComponent
	{
		private var rollover:ADrollOverAble=new ADrollOverAble();
		private var rollout:ADrollOutAble=new ADrollOutAble();
		private var click:ADclickAble=new ADclickAble();
		public function ADbutton()
		{
			super();
//			registerAble()
			initAble();
			registerAble(rollover)
		}
		private function initAble():void
		{
			rollover.stateFunc=rolloverHandle;
			rollout.stateFunc=rolloutHandle;
			click.stateFunc=clickHandle;
		}
		protected function rolloverHandle(skins:*,index:int):void
		{
			state=0;
			//				changeAble(ADrollOverAble,false);
			registerAble(rollout);
			registerAble(click);
			click.isable=true;
			this.filters=[FilterKit.textGlowGF]
		}
		protected function rolloutHandle(skins:*,index:int):void
		{
			state=0;
			//				changeAble(ADrollOutAble,false);
			rollout.isable=false
			rollover.isable=true;
			//				changeAble(ADrollOverAble,true);
			this.filters=[];
		}
		protected  function clickHandle(skins:*,index:int):void
		{
			//				click.isable=false;
		}
//		public function 
	}
}